package com.geh.learn.bean;

/**
 * Created by gehui on 2017/2/23.
 */
public class Student {

    private String sno;

    private String name;

    private int score;

    public Student(String sno, String name, int score) {
        this.sno = sno;
        this.name = name;
        this.score = score;
        //TAAAA
    }

    public String getSno() {
        return sno;
    }

    public void setSno(String sno) {
        this.sno = sno;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getScore() {
        return score;
    }

    public void setScore(int score) {
        this.score = score;
    }

    @Override
    public boolean equals(Object obj) {
        return sno.equals(((Student)obj).getSno());
    }

    @Override
    public int hashCode() {
        return sno.hashCode();
    }

    @Override
    public String toString() {
        return "Student{" +
                "sno='" + sno + '\'' +
                ", name='" + name + '\'' +
                ", score=" + score +
                '}';
    }
}
